// File: sourcefile.h
//
// Author: Dana Burkart
//
// Description: Defines the SourceFile class, which handles the files in an
//              Iterate Project, or otherwise.
//

#ifndef __SOURCE_FILE_H__
#define __SOURCE_FILE_H__

#include <fstream>
#include <vector>
#include <string>
#include <string.h>

#include "common.h"

using namespace std;

class SourceFile {
	public:
		SourceFile(char *filename);
		~SourceFile();
		
		void loadNew(char *filename);
		void load(void);
		void load(char *filename);
		
		const string *getLine(int) const;
		const vector<string> *getLines(void) const;
		int numLines(void) const;
	
	private:
		char *_filename;
		vector<string> _lines;
};

#endif

